package com.iot.broker.mvc.mqtt.handler;

import javax.jms.JMSException;
import javax.jms.TextMessage;
import org.springframework.jms.annotation.JmsListener;
import org.springframework.stereotype.Component;



@Component
public class ConsumerListener {
	
	
	@JmsListener(destination="sys.*.*.thing.property.report", containerFactory="queueListenerFactory")// 增加对应处理的监听器工程
	public void receiveProperty(TextMessage text) throws JMSException{
		System.out.println(text.getText());
	}
	
	@JmsListener(destination="sys.*.*.thing.event.report", containerFactory="queueListenerFactory")// 增加对应处理的监听器工程
	public void receiveEvent(TextMessage text) throws JMSException{
		System.out.println(text.getText());
	}
	
	@JmsListener(destination="sys.*.*.thing.service.report", containerFactory="queueListenerFactory")// 增加对应处理的监听器工程
	public void reportService(TextMessage text) throws JMSException{
		System.out.println(text.getText());
	}

}
